package timing.ukulele.form.client.callback;

import timing.ukulele.form.client.ItemClient;
import timing.ukulele.common.ResponseResult;
import timing.ukulele.common.item.ItemData;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

import java.util.List;

@Component
@Slf4j
public class ItemClientCallback implements ItemClient {
    private final String tips = "事项服务调用失败";

    @Override
    public ResponseResult<ItemData> getByCode(String code) {
        log.error(tips);
        return ResponseResult.rpcError(tips);
    }

    @Override
    public ResponseResult<List<ItemData>> getItemByFormId(Long formTemplateId) {
        log.error(tips);
        return ResponseResult.rpcError(tips);
    }
}
